<template>
  <view class="container">
    <view class="header">
      <uni-icons type="left" size="23" style="vertical-align: middle" @click="goback"></uni-icons>
      <text style="font-size: 36rpx; font-family: PingFang SC, PingFang SC; font-weight: bold; color: #222222; padding-left: 20rpx">{{ detaildata.name }}</text>
    </view>

    <!-- 富文本 -->
    <view class="content"><rich-text :nodes="detaildata.content"></rich-text></view>
  </view>
</template>

<script>
export default {
  onLoad(opt) {
    console.log(JSON.parse(opt.data));
    this.detaildata = JSON.parse(opt.data);
  },
  data() {
    return {
      detaildata: {}
    };
  },
  methods: {
    goback() {
      uni.navigateBack();
    }
  }
};
</script>

<style lang="scss" scoped>
.container {
  box-sizing: border-box;
  .header {
    margin-top: 60rpx;
    margin-left: 30rpx;
  }
  .content {
    width: 750rpx;
    box-sizing: border-box;
    padding: 30rpx;
  }
}
</style>
